package org.example.controller;

import org.example.dao.SpaceDao;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;
import java.util.Map;

@RestController
public class SpaceController {
    @Autowired
    private SpaceDao spaceDao;
    @RequestMapping("/space/findPM")
    public List<Map<String,Object>> findpm(){
        List<Map<String,Object>> result =
                spaceDao.findPM();
        return result;
    }

    @RequestMapping("/space/findPrv")
    public List<Map<String,Object>> findPrv(){
        List<Map<String,Object>> result =
                spaceDao.findPrv();
        return result;
    }

    @RequestMapping("/space/paihang")
    public List<Map<String,Object>> paihang(){
        List<Map<String,Object>> result =
                spaceDao.paihang();
        return result;
    }


}
